<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>无标题文档</title>
</head>

<body>
  
  <?php   
  /* 投递简历处理页 */  
  require_once("../conn/conn_db.php");  
  if($_GET['r_id']!= "" && $_POST['txt_id']!="")
  {
   $uid = $_POST["txt_id"];                     //重新传递用户编号
   $sex = $_POST["txt_sex"];                    //性别
   $name = $_POST["txt_name"];                     //用户姓名
   $education = $_POST["txt_education"];           //学历
   $rname = $_POST["r_name"];                    //投递职位名称
   $rid = $_POST["r_id"];                        //职位编号
   $rtname = $_POST["rt_name"];                   //所属类别名称
   $rtid = $_POST["rt_id"];                      //所属类别编号
   $file = $_POST["txt_file"];                    //简历文件
   $time = date('Y-m-d-h-m');                     //投递时间
	  
   $sql = "insert into file_info (u_id,u_sex,u_name,u_education,r_name,r_id,rt_name,rt_id,u_file,f_time,status) values('$uid','$sex','$name','$education','$rname','$rid','$rtname','$rtid','$file','$time','1')";
    $insert = $conn->query($sql); //执行SQL语句
    if($insert)                  //判断执行结果
    {
        echo "<script>alert('简历投递成功！');self.location='../recruit_info.php?r_id=".$rid."'</script>";
    }
    else
    {
        echo "<script>alert('简历投递失败！');self.location='../recruit_info.php?r_id=".$rid."''</script>";
    }
}
else
{
    echo "<script>alert('请先上传简历！');self.location='../recruit_info.php?r_id=".$rid."''</script>";
}
?>
</body>
</html>